#include<stdio.h>
#include<math.h>
int main()
{double x[100],b;
int i;
double a;
printf("a=");
scanf("%lf",&a);
x[0]=sqrt(a);
for (i=1;i<=100;i++)
{b=x[i-1]+a/x[i-1];
x[i]=(1.0/2.0)*b;
if (fabs(x[i]-x[i-1])<pow(10,-5))
break;}
printf("x=%1.6lf",x[i]);
return 0;
}